package com.qf.usefull.stringdemo;

/**
 * 研究String类的常用方法
 */
public class Demo01 {

    public static void main(String[] args) {

        //1. 这个String类中包含哪些应该了解的内容 （public）

        // String类的Compareble接口的实现逻辑是什么
        String s1 = "helloworld";  //98
        String s2 = "ab";  //97
        String s3 = "中国123123";
        String s4 = "国中";
        String s5 = "a";
        String s6 = "A";
        String age = "10";

//        String join = String.join("-", new String[]{"hello", "world", "hi",s4,s5});
        String join = String.join(",", s1, s2, s3, s4);
        System.out.println(join);
//
//        String s = String.format("Student{name=%s,age=%s}",s4 , age);
//        System.out.println(s);

//        System.out.println(s3.contains("国中"));

//        System.out.println(s5.compareToIgnoreCase(s6));

//        System.out.println(s3.codePointBefore(1));
//        System.out.println(s3.codePointCount(0,3));

//        System.out.println(s3.compareTo(s4));


//        int i = s3.codePointAt(1);
//        System.out.println(i);

//        String s = s1.toString();
//        System.out.println(s);

//        CharSequence charSequence = s1.subSequence(5, s1.length());
//        System.out.println(charSequence);

//        System.out.println(s1.length());

        // charAt(int)
//        char c = s1.charAt(3);
//        System.out.println(c);


//        System.out.println(s1.compareTo(s2));



    }

}
